<?php
require_once 'simpletest/unit_tester.php';
require_once 'simpletest/reporter.php';
require_once __DIR__ . '/../SelectDraftAgeCotroller.php';
require_once APPLICATION_PATH . '/models/Calendar/xml/CalendarXmlController.php';
require_once APPLICATION_PATH . '/models/HttpRequest/HttpRequestController.php';

class SelectDraftAgeTest extends UnitTestCase
{
	public function Test1100()
	{
		$_REQUEST[Names::YOTEIID] = '1347054746.8928';
		$_REQUEST[Names::YOTEIID] = '1347054746.8928';
		$objCalendar = new Models_Calendar_Xml_Controller('201209');
		$objSelectDraftAge = new Components_SelectDraftAgeController($objCalendar);
		$sHtml = $objSelectDraftAge->fetch(0);
		echo $sHtml;
		$sHtml = $objSelectDraftAge->fetch(1);
		echo $sHtml;
	}

	/**
	 * 予定ＩＤなし
	 */
	public function Test1200()
	{
		unset($_REQUEST[Names::YOTEIID]);
		$objCalendar = new Models_Calendar_Xml_Controller('201209');
		$objSelectDraftAge = new Components_SelectDraftAgeController($objCalendar);
		$sHtml = $objSelectDraftAge->fetch(2);
		echo $sHtml;
	}

	/**
	 * 該当予定ＩＤなし
	 */
	public function Test1300()
	{
		$_REQUEST[Names::YOTEIID] = '1347054746.8929';
		$objCalendar = new Models_Calendar_Xml_Controller('201209');
		$objSelectDraftAge = new Components_SelectDraftAgeController($objCalendar);
		$sHtml = $objSelectDraftAge->fetch(2);
		echo $sHtml;
	}
}